package com.dubbo.consumer.controller;

import com.dubbo.consumer.service.ProductAppleService;
import com.dubbo.consumer.service.ProductService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * 产品controller
 */
@RestController
public class ProductController {
    @Autowired
    private ProductAppleService productAppleService;

    @Autowired
    private ProductService productService;

    @RequestMapping("/annot/list")
    public List<String> list() {
        return productService.findList();
    }


    @RequestMapping("/xml/list")
    public List<String> listApple() {
        return productAppleService.listApple();
    }

}
